package com.ruoyi.system.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.Date;

/**
 * 新闻对象 hjly_new
 * 
 * @author ruoyi
 * @date 2022-03-11
 */
public class HjlyNew extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 新闻ID */
    private Integer newId;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "发布时间" ,width = 30, dateFormat = "yyyy-MM-dd")
    private Date createTime;

    /** 新闻标题 */
    @Excel(name = "新闻标题")
    private String newTitle;

    /** 新闻内容 */
    @Excel(name = "新闻内容")
    private String newContent;

    /**  来源 1用户 2红娘 */
    @Excel(name = " 来源", readConverterExp = "1=管理员,2=红娘")
    private String sourceType;

    /** 发布新闻的用户名称 */
    @Excel(name = "发布者姓名")
    private String nickName;

    /** 点赞数 */
    @Excel(name = "点赞数")
    private Integer likeNum;

    /** 收藏数 */
    @Excel(name = "收藏数")
    private Integer collectNum;

    /** 新闻图片 */
//    @Excel(name = "新闻图片")
    private String newImage;

    /** 发布新闻的用户id */
//    @Excel(name = "发布新闻的用户id")
    private Long userId;

    /** 头像 */
    private String avatar;

    /** 置顶值 0:否,1：是 */
//    @Excel(name = "置顶值 0:否,1：是")
    private String sticky;

    /** 是否失效 0有效,1失效 */
//    @Excel(name = "是否失效 0有效,1失效")
    private String disabled;

    /** 置顶时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
//    @Excel(name = "置顶时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date stickyDate;

    /** 置顶排序 */
//    @Excel(name = "置顶排序")
    private Integer stickySort;

    /** 登录用户UserId */
    private Long loginUserId;

    /** 是否以喜欢 */
    private Integer ifLike;

    /** 是否收藏 */
    private Integer ifCollect;

    /** 收藏用户UserId */
    private Long collectUserId;

    public Integer getCollectNum() {
        return collectNum;
    }

    public void setCollectNum(Integer collectNum) {
        this.collectNum = collectNum;
    }

    @Override
    public Date getCreateTime() {
        return createTime;
    }

    @Override
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Integer getIfCollect() {
        return ifCollect;
    }

    public void setIfCollect(Integer ifCollect) {
        this.ifCollect = ifCollect;
    }

    public Long getCollectUserId() {
        return collectUserId;
    }

    public void setCollectUserId(Long collectUserId) {
        this.collectUserId = collectUserId;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public Integer getIfLike() {
        return ifLike;
    }

    public void setIfLike(Integer ifLike) {
        this.ifLike = ifLike;
    }

    public Long getLoginUserId() {
        return loginUserId;
    }

    public void setLoginUserId(Long loginUserId) {
        this.loginUserId = loginUserId;
    }

    public void setNewId(Integer newId) 
    {
        this.newId = newId;
    }

    public Integer getNewId() 
    {
        return newId;
    }
    public void setNewTitle(String newTitle) 
    {
        this.newTitle = newTitle;
    }

    public String getNewTitle() 
    {
        return newTitle;
    }
    public void setNewContent(String newContent) 
    {
        this.newContent = newContent;
    }

    public String getNewContent() 
    {
        return newContent;
    }
    public void setNewImage(String newImage) 
    {
        this.newImage = newImage;
    }

    public String getNewImage() 
    {
        return newImage;
    }
    public void setUserId(Long userId)
    {
        this.userId = userId;
    }

    public Long getUserId()
    {
        return userId;
    }
    public void setNickName(String nickName) 
    {
        this.nickName = nickName;
    }

    public String getNickName() 
    {
        return nickName;
    }
    public void setSourceType(String sourceType) 
    {
        this.sourceType = sourceType;
    }

    public String getSourceType() 
    {
        return sourceType;
    }
    public void setLikeNum(Integer likeNum) 
    {
        this.likeNum = likeNum;
    }

    public Integer getLikeNum() 
    {
        return likeNum;
    }
    public void setSticky(String sticky) 
    {
        this.sticky = sticky;
    }

    public String getSticky() 
    {
        return sticky;
    }
    public void setDisabled(String disabled) 
    {
        this.disabled = disabled;
    }

    public String getDisabled() 
    {
        return disabled;
    }
    public void setStickyDate(Date stickyDate) 
    {
        this.stickyDate = stickyDate;
    }

    public Date getStickyDate() 
    {
        return stickyDate;
    }
    public void setStickySort(Integer stickySort) 
    {
        this.stickySort = stickySort;
    }

    public Integer getStickySort() 
    {
        return stickySort;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("newId", getNewId())
            .append("newTitle", getNewTitle())
            .append("newContent", getNewContent())
            .append("newImage", getNewImage())
            .append("userId", getUserId())
            .append("nickName", getNickName())
            .append("sourceType", getSourceType())
            .append("likeNum", getLikeNum())
            .append("sticky", getSticky())
            .append("disabled", getDisabled())
            .append("stickyDate", getStickyDate())
            .append("stickySort", getStickySort())
            .append("remark", getRemark())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
